import Vue from 'vue' 
import Router from 'vue-router'  
// import Home from "@/views/Home.vue"  
import Brand from "@/components/Brand.vue"  
import Cart from "@/components/Cart.vue"
import HomeList from "@/components/HomeList.vue"  
import Member from "@/components/Member.vue"  
import Menu from "@/components/Menu.vue" 
import companyBackground from "@/components/companyBackground.vue"  
import companyRisk from "@/components/companyRisk.vue"
import companyManager from "@/components/companyManager.vue" 
import homeLeft from "@/components/homeLeft.vue" 
import InfoView from '@/layouts/InfoView'
import Sout from '@/views/Sout.vue'
import GoodsItem from '@/views/GoodsItem.vue'

import Login2 from '../components/Login2.vue'
import Login3 from '../components/Login3.vue'

  
Vue.use(Router)  
  
export default new Router({  
  mode: 'history',  
  base: __dirname,  
  linkActiveClass: 'active', // 更改激活状态的Class值  
  routes: [  
    // {  
    //   path: '/',  
    //   name: 'Home',  
    //   component: Home  
    // },  
    {
      path:'/',
      name:HomeList,
      component:HomeList,
      meta:{ TabbarShow: true },
      redirect: '/HomeList/companyBackground',
      children:  [
        {
          name: 'HomeList',
          path: '/HomeList',
          component: HomeList,
      meta:{ TabbarShow: true },

        },
        {
          name: '/HomeList/companyBackground',
          path: '/HomeList/companyBackground',
          component: companyBackground,
      meta:{ TabbarShow: true },

        },
        {
          name: 'companyRisk',
          path: '/HomeList/companyRisk',
          component: companyRisk,
      meta:{ TabbarShow: true },

        },
        {
          name: 'companyManager',
          path: '/HomeList/companyManager',
      meta:{ TabbarShow: true },
      component: companyManager,
        },
        {
          name: 'homeLeft',
          path: '/HomeList/homeLeft',
      meta:{ TabbarShow: true },
      component: homeLeft,
        },
      ]
     
    },
    {  
      path: '/brand',  
      name: 'Brand',  
      component: Brand ,
      meta:{ TabbarShow: true },

    },  
    {  
      path: '/member',  
      name: 'Member',  
      component: Member  ,
      meta:{ TabbarShow: true },},
      // redirect: '/HomeList/Member',
      // children:[
        {
          name: 'Member',
          path: '/member',
          component: Member,
      meta:{ TabbarShow: true },

        },
        {
          name: 'Login2',
          path: '/member/Login2',
          component: Login2,
      meta:{ TabbarShow: true },

        },
      // ]
    // },  
    {
      path: '/Login2',
      name: 'Login2',
      component:Login2
    },
    {
      path: '/Login3',
      name: 'Login3',
      component:Login3
    },
    {  
      path: '/cart',  
      name: 'Cart',  
      component: Cart ,
      meta:{ TabbarShow: false },

    },
    {  
      path: '/Menu',  
      name: 'Menu',  
      component: Menu  ,
      meta:{ TabbarShow: false },
    
    },
    {
      path: '/about',
      name: 'About',
      component: () => import('../views/About.vue')
    },
    {
      path: '/searchResult',
      name: 'searchResult',
      component: () => import('../views/searchResult.vue')
    },
    {
      path: '/item',
      component: InfoView,
      children: [
        {
          path: '/item/GoodsItem',
          name: 'GoodsItem',
          component: GoodsItem
        },
      ]
    },
    {
      path: '/item/Cart',
      name: 'Cart',
      component: Sout
    },
  ]  
})  